//
//  HPUserService.h
//  LockTest
//
//  Created by ZhangBo on 2018/12/2.
//  Copyright © 2018 ZhangBo. All rights reserved.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN
@class HPUser;
@class RACSignal;

@interface HPUserService : NSObject

//HPUservice遵循单例模式，并可以使用sharedInstance方法。
+ (instancetype)sharedInstance;

- (void)userWithId:(NSString *)uid completion:(void (^)(HPUser *))completion;

- (void)updateUser:(HPUser *)user completion:(void (^)(HPUser *))completion;

- (RACSignal *)signalForUserWithId:(NSString *)uid;

- (RACSignal *)signalForUpdateUser:(HPUser *)user;

- (RACSignal *)signalForUserUpdates:(id)object;
@end

NS_ASSUME_NONNULL_END
